{// 引入标签库 }
<tagLib name="html" />
<include file="Public:header" />
<div class="main">
<div class="main_title">{%EDIT} <a href="{:u("EduTeacher/index")}" class="back_list">{%BACK_LIST}</a></div>
<div class="blank5"></div>
<form name="edit" action="__APP__" method="post" enctype="multipart/form-data">
<table class="form" cellpadding=0 cellspacing=0>
	<tr>
		<td colspan=2 class="topTd"></td>
	</tr>
	<tr>
		<td class="item_title">名称:</td>
		<td class="item_input"><input type="text" class="textbox disabled" name="title" value="{$vo.title}" disabled /></td>
	</tr>
	<tr>
		<td class="item_title">宣传视频:</td>
		<td class="item_input">
			<input type="text" class="textbox" name="file_id" id="file_id" value="{$vo.file_id}" />
			<input type="button" class="button" id="btn_upload" value="上传视频" />
			<span id="result"></span>
		</td>
	</tr>
	<tr>
		<td class="item_title">宣传封面:</td>
		<td class="item_input">
			<html:imgUpload name='desc_image' id='desc_image' value="$vo.desc_image" />
            <span class="tip_span" id="tip_span">&nbsp;[规格为：470px*300px]]</span>
		</td>
	</tr>
	<tr>
		<td class="item_title">教师介绍</td>
		<td class="item_input">
			<input type="text" class="textbox required" style="width: 750px;" name="description" value="{$vo.description}" />
		</td>
	</tr>
	<tr>
		<td class="item_title">标签</td>
		<td class="item_input">
			<ul style="width: 100%">
				<foreach name="tags" item="tag">
				<li style="width: 30%; display: inline-block">
					<label class="col-xs-4">
						<input type="checkbox" name="tags[]" value="{$tag.title}" <if condition="$tag['is_checked'] eq true">checked="checked"</if> > {$tag.title}
					</label>
				</li>
				</foreach>
			</ul>
			<span class="tip_span" id="tip_span">最多选择 3 个标签</span>
		</td>
	</tr>
	<tr>
		<td class="item_title"></td>
		<td class="item_input">
			<!--隐藏元素-->
			<input type="hidden" name="{:conf("VAR_MODULE")}" value="EduTeacher" />
			<input type="hidden" name="{:conf("VAR_ACTION")}" value="update" />
			<input type="hidden" name="id" value="{$vo.id}" />
			<input type="hidden" id="secret_id" value="{$secret_id}" />
			<input type="hidden" id="after_sha_start_upload" value="1" />

			<!--隐藏元素-->
			<input type="submit" class="button" value="{%EDIT}" />
			<input type="reset" class="button" value="{%RESET}" />
		</td>
	</tr>
	<tr>
		<td colspan=2 class="bottomTd"></td>
	</tr>
</table>	 
</form>
</div>
<script>
	$('input[name="tags[]"]').change(function(){
		if($('input[name="tags[]"]:checked').length <= 3) {
			return;
		}

		if(this.checked) {
			this.checked = false;
		}
	});
</script>
<script src="//qzonestyle.gtimg.cn/open/qcloud/js/vod/sdk/uploaderh5.js" charset="utf-8"></script>
<load href='__TMPL__Common/js/user_live.js' />
<include file="Public:footer" />